﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace ArgusLib.Fractals
{
	public struct CalculationProgressChangedEventArgs
	{
		public double Progress { get; private set; }
		public TimeSpan ElapsedTime { get; private set; }
		public object[] Data { get; private set; }

		public CalculationProgressChangedEventArgs(double progress, TimeSpan elapsedTime, params object[] data)
			: this()
		{
			this.Progress = progress;
			this.ElapsedTime = elapsedTime;
			this.Data = data;
		}
	}

	public delegate void CalculationProgressChangedEventHandler(IFractal sender, CalculationProgressChangedEventArgs e);

	public struct CalculationAbortedEventArgs
	{
		public object[] Data { get; private set; }

		public CalculationAbortedEventArgs(params object[] data)
			: this()
		{
			this.Data = data;
		}
	}

	public delegate void CalculationAbortedEventHandler(IFractal sender, CalculationAbortedEventArgs e);

	public struct CalculationFinishedEventArgs
	{
		public TimeSpan ElapsedTime { get; private set; }
		public object[] Data { get; private set; }

		public CalculationFinishedEventArgs(TimeSpan elapsedTime, params object[] data)
			: this()
		{
			this.ElapsedTime = elapsedTime;
			this.Data = data;
		}
	}

	public delegate void CalculationFinishedEventHandler(IFractal sender, CalculationFinishedEventArgs e);
}
